Post

Replies

Boosts

Views

Activity

Reply to Issues with AlarmKit for IOS26+
Working fine here, but I decided to implement it only for 26.2+ because the API versions before that were not as reliable. Remember to first request authorization like this: func requestAuthorization() async -> (granted: Bool, status: String) { do { let state = try await AlarmManager.shared.requestAuthorization() let stateString: String switch state { case .authorized: stateString = "Authorized" case .denied: stateString = "Denied" case .notDetermined: stateString = "Not Determined" @unknown default: stateString = "Unknown" } let granted = state == .authorized print("[AlarmKit] Authorization state: (stateString)") return (granted, stateString) } catch { print("[AlarmKit] Authorization error: (error)") return (false, "Error") } }
1w
Reply to AlarmKit Fixed Schedule Going off at Midnight
@ekurutepe Dang, I'm doing exactly what you were doing. I'll try your new approach. Thanks.
Topic: App & System Services SubTopic: General Tags:
Replies
Boosts
Views
Activity
1w
Reply to Issues with AlarmKit for IOS26+
Working fine here, but I decided to implement it only for 26.2+ because the API versions before that were not as reliable. Remember to first request authorization like this: func requestAuthorization() async -> (granted: Bool, status: String) { do { let state = try await AlarmManager.shared.requestAuthorization() let stateString: String switch state { case .authorized: stateString = "Authorized" case .denied: stateString = "Denied" case .notDetermined: stateString = "Not Determined" @unknown default: stateString = "Unknown" } let granted = state == .authorized print("[AlarmKit] Authorization state: (stateString)") return (granted, stateString) } catch { print("[AlarmKit] Authorization error: (error)") return (false, "Error") } }
Replies
Boosts
Views
Activity
1w
Reply to AlarmKit - Custom Sounds?
Yep, it plays fine now! I recommend sounds shorter than 30 seconds.
Replies
Boosts
Views
Activity
1w
Reply to AlarmKit Fixed Schedule Going off at Midnight
Same here! Many users are complaining about that. I spent a huge amount of time refactoring and testing but could never emulate it.
Topic: App & System Services SubTopic: General Tags:
Replies
Boosts
Views
Activity
1w